/*******************************************************************************
 * Copyright 2011 See AUTHORS file.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *   http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 ******************************************************************************/

package com.asg.guesswhat;


public class Settings {
	//public final static String settingsPath = "";
	//public final static String settingsPath = "C:\\Users\\Blakbro2k\\workspace\\GuessWhat\\guesswhat-desktop\\";
	//public final static String file = ".guesswhat";
	//public final static Config settings = new Config(settingsPath + file);
	
	public static boolean soundEnabled = false;
	public static String username = "blakbro2k";
	public static String email = "blakbro2k@asg.com";
	public static String mobilNumber = "5552345463";
	public static int hostID = 1;
	public static String defaultCardSet = "standard.cset";
	public final static boolean GW_ANDROID = true;
	public final static boolean GW_DESKTOP = false;
	public static boolean isAndroid;
	public static String[] cardSetObj = {"standard","Philip;1,2,3,4;blond","Sam;1,2,3,4;black","Frans;1,2,3,4;","Max;1,2,3,4;","Robert;1,2,3,4;","Alex;1,2,3,4;","Paul;1,2,3,4;","Richard;1,2,3,4;","Anne;1,2,3,4;","David;1,2,3,4;","Peter;1,2,3,4;","Charles;1,2,3,4;","Eric;1,2,3,4;","George;1,2,3,4;","Bill;1,2,3,4;","Susan;1,2,3,4;","Alfred;1,2,3,4;","Bernard;1,2,3,4;","Herman;1,2,3,4;","Anita;1,2,3,4;","Maria;1,2,3,4;","Tom;1,2,3,4;","Joe;1,2,3,4;","Claire;1,2,3,4;"}
;


	public static void load(boolean inSet) {
		isAndroid = inSet;
		System.out.println(isAndroid);
		/*username = settings.getProperty("username");
		if(username.isEmpty()){
			username = "gwplayer21312";
			save("username",username);
		} else {
			username = settings.getProperty("username");
		}
		email = settings.getProperty("email");
		if(email.isEmpty()){
			email = username + "@gw.com";
			save("email",email);
		} else {
			email = settings.getProperty("email");
		}
		//hostID = Integer.parseInt(settings.getProperty("hostID"));
		if(hostID < 1){
			hostID = 312;
			save("hostID",hostID);
		} else {
			hostID = Integer.parseInt(settings.getProperty("hostID"));
		}
		defaultCardSet = settings.getProperty("defaultCardSet");
		if(defaultCardSet.isEmpty()){
			defaultCardSet = "standard.cset";
			save("defaultCardSet",defaultCardSet);
		} else {
			defaultCardSet = settings.getProperty("defaultCardSet");
		}
		soundEnabled = Boolean.parseBoolean(settings.getProperty("soundEnabled"));
		save("soundEnabled","" + soundEnabled);
		//System.out.println(settings.getProperty("soundEnabled"));
		//save("mobilNumber",mobilNumber);*/
	}

	public static void save(String key, String value) {
		//System.out.println("Saving: " + key + ":" + value);
		//settings.setProperty(key,value,file);
	}
	
	public static void save(String key, int value) {
		//System.out.println("Saving: " + key + ":" + value);
		//settings.setProperty(key,"" + value,file);
	}

	public static void toggleSound () {
		soundEnabled = !soundEnabled;
	}
}
